﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace StuertzDatenbank
{
    public partial class ProfilstartGui : Form
    {
        private Sprachfile sprachfile;
         private Benutzer benutzer { get; set; }

        public ProfilstartGui(Benutzer benutzer)
        {
            this.benutzer = benutzer;
            sprachfile = new Sprachfile();
            InitializeComponent();
            InitializeComponentChange();

        }

        private void InitializeComponentChange()
        {
            this.Start.Text = sprachfile.Start;
            this.Text = sprachfile.Profile;
            this.Erstellen.Text = sprachfile.Erstellen;
            this.Suche.Text = sprachfile.Suche;
            this.AlleProfile.Text = sprachfile.AlleProfile;

        }

        private void Erstellen_Click(object sender, EventArgs e)
        {
            this.Visible = false;
            Profilgui gui = new Profilgui(benutzer);
            this.Dispose();
            gui.ShowDialog();
        }

        private void Suche_Click(object sender, EventArgs e)
        {
            this.Visible = false;
            Profilsuchegui gui = new Profilsuchegui(benutzer);
            this.Dispose();
            gui.ShowDialog();
        }

        private void AlleProfile_Click(object sender, EventArgs e)
        {
            this.Visible = false;
            AlleProfilgui gui = new AlleProfilgui(benutzer);
            this.Dispose();
            gui.ShowDialog();
        }

        private void Start_Click(object sender, EventArgs e)
        {
            this.Visible = false;
           startgui gui = new startgui(benutzer);
           this.Dispose();
            gui.ShowDialog();
        }
    }
    }

